/*
 * HEXtoASCII.c
 *
 * Created: 20.02.2013 18:54:32
 *  Author: saenko
 */ 
unsigned char ascii_low;
unsigned char ascii_hi;

unsigned char half_byte_to_ascii(unsigned char data)
{
	data = data & 0b00001111;
	if (data<10) data+=48;
	else data+=55;
	
	return data;
}

void hex_to_ascii(unsigned char data)
{
	ascii_low = half_byte_to_ascii(data);
	data = data>>4;
	ascii_hi = half_byte_to_ascii(data);
}